package edu.groupservice.feignFailBack;

import edu.groupservice.entity.User;
import edu.groupservice.feign.UserServiceFeign;
import feign.Contract;
import feign.Feign;
import feign.Logger;
import feign.auth.BasicAuthRequestInterceptor;
import feign.hystrix.HystrixFeign;
import org.springframework.cloud.netflix.feign.support.SpringMvcContract;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Component;


/**
 * Created by JPhoebe on 2017-7-9.
 */

@Component
public class UserServiceFeignFailBack implements UserServiceFeign {

    @Override
    public User findUserById(long id) {
        User user = new User();
        user.setAge(9);
        user.setId(0);
        user.setName("error");
        user.setRequestPort(0000);
        return user;
    }

}
